# Copyright (c) 2020 Presto Labs Pte. Ltd.
# Author: xguo

REPO_ROOT="$(git rev-parse --show-toplevel)"
cd ${REPO_ROOT}

APP1=""
if [ -d "bazel-bin" ]; then
  APP1="$(find bazel-bin/ -type f -name oe_dumper)"
fi

APP2=""
if [ -d "../coin_binary" ]; then
  APP2="$(find ../coin_binary/ -type f -name oe_dumper)"
fi

APP="${APP1:-$APP2}"

${APP} \
  --owner=prestoinvt46 \
  --mea=Spot.Huobi.v1 \
  --machine=strategy-45.ap-northeast-1.huobi \
  --trading_date=20200325 $@
